﻿using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace Week3_1_Repository.Migrations
{
    public partial class 订单商品1 : Migration
    {
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.CreateTable(
                name: "OrderGoods",
                columns: table => new
                {
                    OGid = table.Column<int>(type: "int", nullable: false)
                        .Annotation("SqlServer:Identity", "1, 1"),
                    GCode = table.Column<string>(type: "nvarchar(max)", nullable: true),
                    OCode = table.Column<string>(type: "nvarchar(max)", nullable: true),
                    BuyCount = table.Column<int>(type: "int", nullable: false),
                    SumPrice = table.Column<decimal>(type: "decimal(18,2)", nullable: false),
                    Uid = table.Column<int>(type: "int", nullable: false)
                },
                constraints: table =>
                {
                    table.PrimaryKey("PK_OrderGoods", x => x.OGid);
                });
        }

        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropTable(
                name: "OrderGoods");
        }
    }
}
